package com.yanqu.road.entity.activity.treasure;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.FieldTypeAnnotation;
import com.yanqu.road.entity.DataStatus;

@FieldTypeAnnotation(tableName = "t_u_activity_treasure")
public class UserTreasureActivityData extends DataObject {
    @FieldTypeAnnotation(select = true, update = true, desc = "用户id")
    private long userId;
    @FieldTypeAnnotation(select = true, update = true, desc = "活动id")
    private int activityId;
    @FieldTypeAnnotation(desc = "用户当前旅行下标")
    private int routeIndex;
    @FieldTypeAnnotation(desc = "当前领奖的圈数")
    private int rewardRound;
    @FieldTypeAnnotation(desc = "成就进度值")
    private int taskProgress;
    @FieldTypeAnnotation(desc = "使用的送宝次数")
    private int useTimes;
    @FieldTypeAnnotation(desc = "积分")
    private long score;

    private int hasTimes;
    private int placeId;
    private int routeProgress;
    private int round;

    public void setUserId(long userId) {
        if (this.userId != userId) {
            this.userId = userId;
            setOp(DataStatus.Update);
        }

    }

    public void setActivityId(int activityId) {
        if (this.activityId != activityId) {
            this.activityId = activityId;
            setOp(DataStatus.Update);
        }

    }

    public void setRouteIndex(int routeIndex) {
        if (this.routeIndex != routeIndex) {
            this.routeIndex = routeIndex;
            setOp(DataStatus.Update);
        }

    }

    public void setRewardRound(int rewardRound) {
        if (this.rewardRound != rewardRound) {
            this.rewardRound = rewardRound;
            setOp(DataStatus.Update);
        }

    }

    public void setTaskProgress(int taskProgress) {
        if (this.taskProgress != taskProgress) {
            this.taskProgress = taskProgress;
            setOp(DataStatus.Update);
        }

    }

    public void setUseTimes(int useTimes) {
        if (this.useTimes != useTimes) {
            this.useTimes = useTimes;
            setOp(DataStatus.Update);
        }

    }

    public void setScore(long score) {
        if (this.score != score) {
            this.score = score;
            setOp(DataStatus.Update);
        }

    }

    public int getRound() {
        return round;
    }

    public long getUserId() {
        return userId;
    }

    public int getActivityId() {
        return activityId;
    }

    public int getPlaceId() {
        return placeId;
    }

    public int getRouteProgress() {
        return routeProgress;
    }

    public int getTaskProgress() {
        return taskProgress;
    }

    public int getHasTimes() {
        return hasTimes;
    }

    public int getUseTimes() {
        return useTimes;
    }

    public long getScore() {
        return score;
    }

    public int getRouteIndex() {
        return routeIndex;
    }

    public int getRewardRound() {
        return rewardRound;
    }

    @Override
    public String toString() {
        return "UserTreasureActivityData{" +
                "userId=" + userId +
                ", routeIndex=" + routeIndex +
                ", rewardRound=" + rewardRound +
                ", taskProgress=" + taskProgress +
                ", useTimes=" + useTimes +
                ", score=" + score +
                '}';
    }
}
